home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Night Owl 6
/
Night Owl's Shareware - PDSI-006 - Night Owl Corp (1990).iso
/
015a
/
inskey.zip
/
INSKEY.DOC
< prev
next >
Wrap
Text File
|
1991-11-18
|
2KB
|
49 lines
INSKEY.DOC
INSKEY.COM is a very small utility that allows a program to run,
(or not run) depending on whether or not the insert is toggled on
(or off). It is useful when you want to load TSR's or run
programs from a batch file on a conditional basis. It is
particularly useful in AUTOEXEC.BAT to go/not go into windows, or
to load/not load a TSR. INSKEY.COM returns the ERRORLEVEL 128 if
the insert has been toggled on.
Use INSKEY.COM in a batch file as below :
INSKEY
IF ERRORLEVEL 128 Win
The above sequence will cause the batch file to execute the Win
command (and thus run Windows) only if the Insert key was toggled
On before running the batch file. Thus, if this was the
AUTOEXEC.BAT file, and you want to run windows on boot-up, press
the insert key while the computer is booting.
If you prefer, the insert key can be replaced by another key by
altering the INSKEY.SCR file to create a different COM file.
Change the 128 in line 5 ( AND AL,128 ) in the .SCR file to
another code given in the table below, and re-compile to generate
another .COM file.
KEY CODE
___ ____
Right Shift 1 (Hold key down)
Left Shift 2 (Hold key down)
Ctrl 4 (Hold key down)
Alt 8 (Hold key down)
Scroll Lock 16 (Toggle)
Num Lock 32 (Toggle)
Caps Lock 64 (Toggle)
Insert 128 (Toggle)
Run the .SCR file through the dos utility DEBUG, by giving the
command DEBUG<INSKEY.SCR, to generate a new INSKEY.COM. You may
give INSKEY.COM another relevant name, like RSHIFT.COM for Right
Shift.
Ignore the error if you recompile the INSKEY.SCR code using the AND AL,128.